<div class="form-group"> 
					<label class="col-xs-12 col-sm-3 col-md-2 col-lg-2 control-label">服务方式</label>
					<div class="col-xs-12 col-sm-8">
						<div class="input-group">
						<label class="radio radio-inline"  onclick="$('.type').hide();$('.type1').show();">
							<input type="radio" name="goods[deliverytype]" value="1" {if intval($goods['deliverytype']) ==1 }checked="checked"{/if}> 上门服务
						</label>

						<label class="radio radio-inline"  onclick="$('.type').hide();$('.type1').show();">
							<input type="radio" name="goods[deliverytype]" value="2" {if intval($goods['deliverytype']) ==2 }checked="checked"{/if}> 到店消费
						</label>

						<!--<label class="radio radio-inline"  onclick="$('.type').hide();$('.type1').show();">-->
							<!--<input type="radio" name="goods[deliverytype]" value="3" {if intval($goods['deliverytype']) ==3 }checked="checked"{/if}> 上门服务+到店消费-->
						<!--</label>-->

						</div>
					</div>
				</div>


<div class="form-group">
	<label class="col-xs-12 col-sm-3 col-md-2 control-label">自提门店选择</label>
	<div class="col-sm-9 col-xs-12 chks">
		<div class='input-group'>
			<input type="text" name="saler" maxlength="30" value="{loop $salers $saler} {$saler['nickname']}; {/loop}" id="saler" class="form-control" readonly />
			<div class='input-group-btn'>
				<button class="btn btn-default" type="button" onclick="popwin = $('#modal-module-menus').modal();">选择门店</button>
			</div>
		</div>

		<div style="margin-top:.5em;" class="input-group multi-audio-details clear-fix" id='stores'>{loop $stores $store}
			<div style="height: 40px; position:relative; float: left; margin-right: 18px;" class="multi-audio-item" storeid="{$store['id']}">
				<div class="input-group">
					<input type="hidden" value="{$store['id']}" name="storeids[]">
					<input type="text" value="{$store['storename']}" readonly="" class="form-control">
					<div class="input-group-btn">
						<button type="button" onclick="remove_store(this)" class="btn btn-default"><i class="fa fa-remove"></i></button>
					</div>
				</div>
			</div>
			{/loop}</div>
		<span class='help-block'>配送方式选择中有到店消费时,必须最少选择一个门店点</span>

		<div id="modal-module-menus" class="modal fade" tabindex="-1">
			<div class="modal-dialog" style='width: 920px;'>
				<div class="modal-content">
					<div class="modal-header">
						<button aria-hidden="true" data-dismiss="modal" class="close" type="button">×</button>
						<h3>选择门店</h3></div>
					<div class="modal-body">
						<div class="row">
							<div class="input-group">
								<input type="text" class="form-control" name="keyword" value="" id="search-kwd" placeholder="请输入门店名称" />
								<span class='input-group-btn'><button type="button" class="btn btn-default" onclick="search_stores();">搜索</button></span>
							</div>
						</div>
						<div id="module-menus" style="padding-top:5px;"></div>
					</div>
					<div class="modal-footer"><a href="#" class="btn btn-default" data-dismiss="modal" aria-hidden="true">关闭</a></div>
				</div>

			</div>
		</div>
	</div>

</div>

<script language='javascript'>
	function search_stores() {
			$("#module-menus").html("正在搜索....")
			$.get('{php echo web_url('application/bdelete/selectstore')}', {
				keyword: $.trim($('#search-kwd').val())
			}, function(dat){
				$('#module-menus').html(dat);
			});
		}
	function remove_store(obj){
	        var storeid = $(obj).closest('.multi-audio-item').attr('storeid');
	        	$('.multi-audio-item[storeid="' + storeid +'"]').remove();
	    }
	function select_store(o) {
	                        if($('.multi-audio-item[storeid="' + o.id +'"]').length>0){
	                            return;
	                        }
	                        var html ='<div style="height: 40px; position:relative; float: left; margin-right: 18px;" class="multi-audio-item" storeid="' + o.id +'">';
	                html+='<div class="input-group">';
	                    html+='<input type="hidden" value="' + o.id +'" name="storeids[]">';
	                    html+='<input type="text" value="' + o.storename +'" readonly="" class="form-control">';
	                    html+='<div class="input-group-btn"><button type="button" onclick="remove_store(this)" class="btn btn-default"><i class="fa fa-remove"></i></button></div>';
	             html+='</div></div>';
	                        $('#stores').append(html);
	 	}
</script>
<script language='javascript'>
	function search_dispatch() {
			$("#module-menus1").html("正在搜索....")
			$.get('{php echo web_url('application/bdelete/selectdispatch')}', {
				keyword: $.trim($('#search-kwd1').val())
			}, function(dat){
				$('#module-menus1').html(dat);
			});
		}
	function remove_dispatch(obj){
	        var dispatchid = $(obj).closest('.multi-audio-item').attr('dispatchid');
	        	$('.multi-audio-item[dispatchid="' + dispatchid +'"]').remove();
	    }
	function select_dispatch(o) {
	                        if($('.multi-audio-item[dispatchid="' + o.id +'"]').length>0){
	                            return;
	                        }
	                        var html ='<div style="height: 40px; position:relative; float: left; margin-right: 18px;" class="multi-audio-item" dispatchid="' + o.id +'">';
	                html+='<div class="input-group">';
	                    html+='<input type="hidden" value="' + o.id +'" name="dispatchs[]">';
	                    html+='<input type="text" value="' + o.name +'" readonly="" class="form-control">';
	                    html+='<div class="input-group-btn"><button type="button" onclick="remove_dispatch(this)" class="btn btn-default"><i class="fa fa-remove"></i></button></div>';
	             html+='</div></div>';
	                        $('#dispatch').append(html);
	 	}
</script>